import { API_CONFIG } from "../config/index.js";
import request from './index.js'

export const getNamespaceListHandler=(clusterId)=>{
    return request(API_CONFIG.getNamespaceListApi, {clusterId},"get","2000")
}


export const createNamespaceHandler=(clusterId,name)=>{
    return request(API_CONFIG.createNamespaceApi, {clusterId,name},"post","2000")
}


export const deleteNamespaceHandler=(clusterId,name)=>{
    return request(API_CONFIG.deleteNamespaceApi, {clusterId,name},"get","2000")
}

export const updateNamespaceHandler=(clusterId,name,item)=>{
    return request(API_CONFIG.updateNamespaceApi, {clusterId,name,item},"post","2000")
}
